#include <bits/stdc++.h>

using namespace std;

int xt,yt,xm,ym,cnt;
bool ishorse[30][30];
int xx[] = {1,1,-1,-1,2,2,-2,-2};
int yy[] = {-2,2,-2,2,-1,1,-1,1};
void dfs(int x,int y){
    if(x==xt&&y==yt){
        cnt++;
        return;
    }
    if(x<=xt-1&&!ishorse[x+1][y])dfs(x+1,y);
    if(y<=yt-1&&!ishorse[x][y+1])dfs(x,y+1);
}
int main()
{
    cin>>xt>>yt>>xm>>ym;
    ishorse[xm][ym]=1;
    for(int i=0;i<8;i++){
        if((xm+xx[i])>=0&&(xm+xx[i])<=xt&&(ym+yy[i])<=yt&&(ym+yy[i])>=0)
        ishorse[xm+xx[i]][ym+yy[i]]=1;
    }
    dfs(0,0);
    cout<<cnt;
    return 0;
}
